<html>
<body>
<h1>XML Plugin</h1>
<p>
    The XML plugin allows transformations of XML via XSLT using bundled XML catalogs.
</p>

<div id="after-summary">
    <p>If using the defaults, add any XML catalogues you are using to the xml-catalog path and
    add the XML transform library to the xml-transform classpath (e.g. saxon). You will also
        need to add ant-trax to the transform classpath is most cases.
    </p>
    <p>The following is an example of using Saxon to transform a docbook file:</p>
    <pre>&lt;dependency group="sf.saxon" version="6.5.3" paths="xml-transform"/&gt;
&lt;dependency group="sf.docbook.xsl" name="saxon65-ext" version="1.72" paths="xml-transform"/&gt;
&lt;dependency group="apache.ant" name="trax" version="1.7.1" paths="xml-transform"/&gt;

&lt;dependency group="quokka.xmlcat.docbook-xsl-1-72-0" version="0.1.1-ss" paths="xml-catalog"/&gt;
&lt;dependency group="quokka.xmlcat.docbook-dtd-4-5" version="0.1.1-ss" paths="xml-catalog"/&gt;

&lt;plugin group="quokka.plugin.xml" version="?"&gt;
    &lt;target template="transform" name="docbook" prefix="myproj.docbook"&gt;
        &lt;property name="in" value="src/docbook/master.xml"/&gt;
        &lt;property name="out" value="${q.project.targetDir}/docbook/fo.xml"/&gt;
        &lt;property name="style" value="src/docbook/styles/fopdf.xsl"/&gt;
        &lt;property name="factory" value="com.icl.saxon.TransformerFactoryImpl"/&gt;
    &lt;/target&gt;
&lt;/plugin&gt;
</pre>
</div>

<div id="transform">
    <p><b>Properties:</b></p>
    <p>All properties are optional unless stated otherwise.</p>
    <table >
        <tr>
            <td>out</td>
            <td>The output file if transforming a single document</td>
        </tr>
        <tr>
            <td>destDir</td>
            <td>The destination directory if transforming mulitple documents</td>
        </tr>
        <tr>
            <td>transformClassPath</td>
            <td>The project path that contains the xml processor to use for the transform</td>
        </tr>
        <tr>
            <td>style</td>
            <td>Mandatory. The stylesheet to use</td>
        </tr>
        <tr>
            <td>factory</td>
            <td>The class name of the factory to use. e.g. com.icl.saxon.TransformerFactoryImpl</td>
        </tr>
        <tr>
            <td>factory.params[]</td>
            <td>A map of strings that are passed to the factory as parameters</td>
        </tr>
        <tr>
            <td>params[]</td>
            <td>A map of strings that are passed to the stylesheet as parameters</td>
        </tr>
        <tr>
            <td>outputProperty[]</td>
            <td>A map of strings that are passed as output properties to the transform</td>
        </tr>
        <tr>
            <td>catalogPath</td>
            <td>The project path containing any catalogues used during the tranform, such as the docbook catalogue.</td>
        </tr>
        <tr>
            <td valign="top">basedir</td>
            <td valign="top">where to find the source XML file, default is the
              project's basedir.</td>
          </tr>
          <tr>
            <td valign="top">extension</td>
            <td valign="top">desired file extension to be used for the targets. If not
              specified, the default is &quot;.html&quot;.  Will be ignored if
              a nested <code>&lt;mapper&gt;</code> has been specified.</td>
          </tr>
          <tr>
            <td valign="top">force</td>
            <td valign="top">Recreate target files, even if they are newer
              than their corresponding source files or the stylesheet. Defaults to false</td>
          </tr>

          <tr>
            <td valign="top">includes</td>
            <td valign="top">comma- or space-separated list of patterns of files that must be included.
              All files are included when omitted.</td>
          </tr>
          <tr>
            <td valign="top">includesFile</td>
            <td valign="top">the name of a file. Each line of this file is taken to be
              an include pattern</td>
          </tr>
          <tr>

            <td valign="top">excludes</td>
            <td valign="top">comma- or space-separated list of patterns of files that must be excluded.
              No files (except default excludes) are excluded when omitted.</td>
          </tr>
          <tr>
            <td valign="top">excludesFile</td>
            <td valign="top">the name of a file. Each line of this file is taken to be
              an exclude pattern</td>
          </tr>
          <tr>
            <td valign="top">defaultExcludes</td>
            <td valign="top">indicates whether default excludes should be used or not
              (&quot;yes&quot;/&quot;no&quot;). Default excludes are used when omitted.</td>
          </tr>
          <tr>
            <td valign="top">scanIncludedDirectories</td>

            <td valign="top">If any directories are matched by the
              includes/excludes patterns, try to transform all files in these
              directories.  Default is <code>true</code></td>
          </tr>
    </table>
</div>


</body>
</html>